﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace SmartMathLibrary.Storage
{
    /// <summary>
    /// This class represents a definition of storage data selection.
    /// </summary>
    [Serializable]
    public class StorageSelectionResult
    {
        /// <summary>
        /// The first storage index of the selection.
        /// </summary>
        private int firstIndex;

        /// <summary>
        /// The last storage index of the selection.
        /// </summary>
        private int lastIndex;

        /// <summary>
        /// Initializes a new instance of the <see cref="StorageSelectionResult"/> class.
        /// </summary>
        public StorageSelectionResult()
        {
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="StorageSelectionResult"/> class.
        /// </summary>
        /// <param name="firstIndex">The first storage index of the selection.</param>
        /// <param name="lastIndex">The last storage index of the selection.</param>
        public StorageSelectionResult(int firstIndex, int lastIndex)
        {
            this.firstIndex = firstIndex;
            this.lastIndex = lastIndex;
        }

        /// <summary>
        /// Gets or sets the first storage index of the selection.
        /// </summary>
        /// <value>The first storage index of the selection.</value>
        public int FirstIndex
        {
            get { return firstIndex; }
            set { firstIndex = value; }
        }

        /// <summary>
        /// Gets or sets the last storage index of the selection.
        /// </summary>
        /// <value>The last storage index of the selection.</value>
        public int LastIndex
        {
            get { return lastIndex; }
            set { lastIndex = value; }
        }
    }
}